﻿using SHomeWorkshop.LunarSF.StudentInfosManager.ValidationRules;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Linq;
using System.Text;

namespace SHomeWorkshop.LunarSF.StudentInfosManager
{
    public class StudentEcnomicInfos : INotifyPropertyChanged
    {
        public event PropertyChangedEventHandler PropertyChanged;
        /// <summary>
        /// 属性值发生变化时产生通知事件。
        /// </summary>
        public void OnPropertyChanged(object sender, PropertyChangedEventArgs e)
        {
            if (PropertyChanged != null)
            {
                PropertyChanged(sender, e);
            }
        }

        public override string ToString()
        {
            StringBuilder sBuilder = new StringBuilder();

            //其实可以用反射，但这样更简单些。类似下面这样：
            sBuilder.Append($"{nameof(SavingCardNumber)}|{SavingCardNumber}\r\n");
            sBuilder.Append($"{nameof(SavingCardBankName)}|{SavingCardBankName}\r\n");
            sBuilder.Append($"{nameof(SavingCardOwnerName)}|{SavingCardOwnerName}\r\n");

            sBuilder.Append($"{nameof(SavingCardOwnerRelationship)}|{SavingCardOwnerRelationship}\r\n");
            sBuilder.Append($"{nameof(SavingCardOwnerCid)}|{SavingCardOwnerCid}\r\n");
            sBuilder.Append($"{nameof(IsFiveGuaranteesFamily)}|{IsFiveGuaranteesFamily}\r\n");

            sBuilder.Append($"{nameof(IsBasicLivingAllowances)}|{IsBasicLivingAllowances}\r\n");
            sBuilder.Append($"{nameof(IsSingleParentChild)}|{IsSingleParentChild}\r\n");
            sBuilder.Append($"{nameof(IsDeformityParentsChild)}|{IsDeformityParentsChild}\r\n");

            sBuilder.Append($"{nameof(StudentDeformityStatus)}|{StudentDeformityStatus}\r\n");
            sBuilder.Append($"{nameof(IsParentsCanNotWork)}|{IsParentsCanNotWork}\r\n");
            sBuilder.Append($"{nameof(IsSeriousIllnessInTheFamily)}|{IsSeriousIllnessInTheFamily}\r\n");

            sBuilder.Append($"{nameof(IsArmyOrSpecialCaredChild)}|{IsArmyOrSpecialCaredChild}\r\n");
            sBuilder.Append($"{nameof(AnnualHouseholdIncome)}|{AnnualHouseholdIncome}\r\n");
            sBuilder.Append($"{nameof(SourceOfFamilyIncome)}|{SourceOfFamilyIncome}\r\n");

            sBuilder.Append($"{nameof(IsSufferFromNaturalDisasters)}|{IsSufferFromNaturalDisasters}\r\n");
            sBuilder.Append($"{nameof(NaturalDisastersDiscription)}|{NaturalDisastersDiscription}\r\n");
            sBuilder.Append($"{nameof(IsUnexpectedAccidentHappened)}|{IsUnexpectedAccidentHappened}\r\n");

            sBuilder.Append($"{nameof(UnexpectedAccidentDiscription)}|{UnexpectedAccidentDiscription}\r\n");
            sBuilder.Append($"{nameof(AmountOfDebt)}|{AmountOfDebt}\r\n");
            sBuilder.Append($"{nameof(DebtReson)}|{DebtReson}\r\n");

            sBuilder.Append($"{nameof(FamilyMembersCount)}|{FamilyMembersCount}\r\n");
            sBuilder.Append($"{nameof(SupportPersonsCount)}|{SupportPersonsCount}\r\n");
            sBuilder.Append($"{nameof(IsRegistedPoorFamily)}|{IsRegistedPoorFamily}\r\n");

            sBuilder.Append($"{nameof(IsRegistedBasicLivingAllowances)}|{IsRegistedBasicLivingAllowances}\r\n");
            sBuilder.Append($"{nameof(OtherInfosFromCivilDepartment)}|{OtherInfosFromCivilDepartment}\r\n");
            sBuilder.Append($"{nameof(LaborCountOfFamily)}|{LaborCountOfFamily}\r\n");

            sBuilder.Append($"{nameof(UnemployedCountOfFamily)}|{UnemployedCountOfFamily}\r\n");
            sBuilder.Append($"{nameof(OtherInfos)}|{OtherInfos}\r\n");



            //TODO: 每新加一个字段，都要在这里添加

            return sBuilder.ToString();
        }

        public string BlankErrorText
        {
            get
            {
                StringBuilder sb = new StringBuilder();

                //县局尚未回复，不能要求输入银行卡号。
                //if (string.IsNullOrWhiteSpace(SavingCardNumber)) sb.Append($"{nameof(SavingCardNumber)}\r\n");
                //if (string.IsNullOrWhiteSpace(SavingCardBankName)) sb.Append($"{nameof(SavingCardBankName)}\r\n");
                //if (string.IsNullOrWhiteSpace(SavingCardOwnerName)) sb.Append($"{nameof(SavingCardOwnerName)}\r\n");

                //if (string.IsNullOrWhiteSpace(SavingCardOwnerRelationship)) sb.Append($"{nameof(SavingCardOwnerRelationship)}\r\n");
                //if (string.IsNullOrWhiteSpace(SavingCardOwnerCid)) sb.Append($"{nameof(SavingCardOwnerCid)}\r\n");

                //是否五保户
                if (string.IsNullOrWhiteSpace(IsFiveGuaranteesFamily)) sb.Append($"{nameof(IsFiveGuaranteesFamily)}（是否五保户）\r\n");

                //是否低保户
                if (string.IsNullOrWhiteSpace(IsBasicLivingAllowances)) sb.Append($"{nameof(IsBasicLivingAllowances)}（是否低保户）\r\n");

                //是否单亲家庭
                if (string.IsNullOrWhiteSpace(IsSingleParentChild)) sb.Append($"{nameof(IsSingleParentChild)}（是否单亲家庭）\r\n");

                //是否残疾人子女
                if (string.IsNullOrWhiteSpace(IsDeformityParentsChild)) sb.Append($"{nameof(IsDeformityParentsChild)}（是否残疾人子女）\r\n");

                //学生本人残疾情况
                if (string.IsNullOrWhiteSpace(StudentDeformityStatus)) sb.Append($"{nameof(StudentDeformityStatus)}（学生本人残疾情况）\r\n");

                //是否父母丧失劳动能力
                if (string.IsNullOrWhiteSpace(IsParentsCanNotWork)) sb.Append($"{nameof(IsParentsCanNotWork)}（是否父母丧失劳动能力）\r\n");

                //是否家中有大病患者
                if (string.IsNullOrWhiteSpace(IsSeriousIllnessInTheFamily)) sb.Append($"{nameof(IsSeriousIllnessInTheFamily)}（是否家中有大病患者）\r\n");

                //是否军烈属或优抚子女
                if (string.IsNullOrWhiteSpace(IsArmyOrSpecialCaredChild)) sb.Append($"{nameof(IsArmyOrSpecialCaredChild)}（是否军烈属或优抚子女）\r\n");

                //家庭人均年收入
                if (string.IsNullOrWhiteSpace(AnnualHouseholdIncome)) sb.Append($"{nameof(AnnualHouseholdIncome)}（家庭人均年收入）\r\n");

                //家庭主要收入来源类型
                if (string.IsNullOrWhiteSpace(SourceOfFamilyIncome)) sb.Append($"{nameof(SourceOfFamilyIncome)}（家庭主要收入来源类型）\r\n");

                //是否遭受自然灾害
                if (string.IsNullOrWhiteSpace(IsSufferFromNaturalDisasters)) sb.Append($"{nameof(IsSufferFromNaturalDisasters)}（是否遭受自然灾害）\r\n");

                //自然灾害具体情况描述
                //if (string.IsNullOrWhiteSpace(NaturalDisastersDiscription)) sb.Append($"{nameof(NaturalDisastersDiscription)}（自然灾害具体情况描述）\r\n");

                //是否遭受突发意外事件
                if (string.IsNullOrWhiteSpace(IsUnexpectedAccidentHappened)) sb.Append($"{nameof(IsUnexpectedAccidentHappened)}（是否遭受突发意外事件）\r\n");

                //突发意外事件情况描述
                //if (string.IsNullOrWhiteSpace(UnexpectedAccidentDiscription)) sb.Append($"{nameof(UnexpectedAccidentDiscription)}（突发意外事件情况描述）\r\n");

                //家庭欠债金额
                if (string.IsNullOrWhiteSpace(AmountOfDebt)) sb.Append($"{nameof(AmountOfDebt)}（家庭欠债金额）\r\n");

                //家庭欠债原因
                //if (string.IsNullOrWhiteSpace(DebtReson)) sb.Append($"{nameof(DebtReson)}（家庭欠债原因）\r\n");

                //家庭人口数
                if (string.IsNullOrWhiteSpace(FamilyMembersCount)) sb.Append($"{nameof(FamilyMembersCount)}（家庭人口数）\r\n");

                //赡养人口数
                if (string.IsNullOrWhiteSpace(SupportPersonsCount)) sb.Append($"{nameof(SupportPersonsCount)}（赡养人口数）\r\n");

                //是否建档立卡贫困户
                if (string.IsNullOrWhiteSpace(IsRegistedPoorFamily)) sb.Append($"{nameof(IsRegistedPoorFamily)}（是否建档立卡贫困户）\r\n");

                //是否建档立卡低保贫困户
                if (string.IsNullOrWhiteSpace(IsRegistedBasicLivingAllowances)) sb.Append($"{nameof(IsRegistedBasicLivingAllowances)}（是否建档立卡低保贫困户）\r\n");

                //民政部门其它信息
                //if (string.IsNullOrWhiteSpace(OtherInfosFromCivilDepartment)) sb.Append($"{nameof(OtherInfosFromCivilDepartment)}（民政部门其它信息）\r\n");

                //劳动力人口数
                if (string.IsNullOrWhiteSpace(LaborCountOfFamily)) sb.Append($"{nameof(LaborCountOfFamily)}（劳动力人口数）\r\n");

                //家庭失业人口数
                if (string.IsNullOrWhiteSpace(UnemployedCountOfFamily)) sb.Append($"{nameof(UnemployedCountOfFamily)}（家庭失业人口数）\r\n");

                //困难情况具体说明
                //if (string.IsNullOrWhiteSpace(OtherInfos)) sb.Append($"{nameof(OtherInfos)}（困难情况具体说明）\r\n");

                //if (string.IsNullOrWhiteSpace()) sb.Append($"{nameof()}\r\n");

                var result = sb.ToString();

                if (string.IsNullOrWhiteSpace(result)) return "";

                return $"以下字段未设置值：\r\n{result}";
            }
        }

        string savingCardNumber = "";
        /// <summary>
        /// 银行卡号。
        /// </summary>
        public string SavingCardNumber
        {
            get { return savingCardNumber; }
            set
            {
                savingCardNumber = value;
                OnPropertyChanged(this, new PropertyChangedEventArgs(nameof(SavingCardNumber)));
            }
        }

        string savingCardBankName = "中国邮政储蓄银行";
        /// <summary>
        /// 储蓄卡所属银行名称。
        /// 只支持五家银行之一：中国工商银行、中国建设银行、中国农业银行、中国银行、中国邮政储蓄银行。
        /// </summary>
        public string SavingCardBankName
        {
            get { return savingCardBankName; }
            set
            {
                savingCardBankName = value;
                OnPropertyChanged(this, new PropertyChangedEventArgs(nameof(SavingCardBankName)));
            }
        }

        string savingCardOwnerName = "";
        /// <summary>
        /// 持卡人姓名。
        /// </summary>
        public string SavingCardOwnerName
        {
            get { return savingCardOwnerName; }
            set
            {
                savingCardOwnerName = value;
                OnPropertyChanged(this, new PropertyChangedEventArgs(nameof(SavingCardOwnerName)));
            }
        }

        string savingCardOwnerRelationship = "本人";
        /// <summary>
        /// 持卡人与学生关系。应为以下四种值之一：父亲、母亲、近亲属、其他。
        /// </summary>
        public string SavingCardOwnerRelationship
        {
            get { return savingCardOwnerRelationship; }
            set
            {
                savingCardOwnerRelationship = value;
                OnPropertyChanged(this, new PropertyChangedEventArgs(nameof(SavingCardOwnerRelationship)));
            }
        }

        string savingCardOwnerCid = "";
        /// <summary>
        /// 持卡人身份证号。
        /// ★持卡人通常应是本人，如不是本人，应优先考虑父母或监护人。
        /// </summary>
        public string SavingCardOwnerCid
        {
            get { return CIDRule.Format(savingCardOwnerCid); }
            set
            {
                savingCardOwnerCid = value;
                OnPropertyChanged(this, new PropertyChangedEventArgs(nameof(SavingCardOwnerCid)));
            }
        }


        string studentDeformityStatusConverter = "无残疾";
        /// <summary>
        /// 学生本人残疾情况。
        /// </summary>
        public string StudentDeformityStatusConverter
        {
            get { return studentDeformityStatusConverter; }
            set
            {
                studentDeformityStatusConverter = value;
                OnPropertyChanged(this, new PropertyChangedEventArgs(nameof(StudentDeformityStatusConverter)));
            }
        }

        string isFiveGuaranteesFamily = "";
        /// <summary>
        /// 是否五保户。
        /// ★注意：是文本型。只允许“是”和“否”。
        /// </summary>
        public string IsFiveGuaranteesFamily
        {
            get { return isFiveGuaranteesFamily; }
            set
            {
                isFiveGuaranteesFamily = value;
                OnPropertyChanged(this, new PropertyChangedEventArgs(nameof(isFiveGuaranteesFamily)));
            }
        }

        string isBasicLivingAllowances = "";
        /// <summary>
        /// 是否低保家庭。
        /// ★注意：是文本型。只允许“是”和“否”。
        /// </summary>
        public string IsBasicLivingAllowances
        {
            get { return isBasicLivingAllowances; }
            set
            {
                isBasicLivingAllowances = value;
                OnPropertyChanged(this, new PropertyChangedEventArgs(nameof(IsBasicLivingAllowances)));
            }
        }

        string isOrphan = "";
        /// <summary>
        /// 是否孤儿。
        /// ★注意：是文本型。只允许“是”和“否”。
        /// </summary>
        public string IsOrphan
        {
            get { return isOrphan; }
            set
            {
                isOrphan = value;
                OnPropertyChanged(this, new PropertyChangedEventArgs(nameof(IsOrphan)));
            }
        }

        string isSingleParentChild = "";
        /// <summary>
        /// 是否单亲家庭子女。
        /// ★注意：是文本型。只允许“是”和“否”。
        /// </summary>
        public string IsSingleParentChild
        {
            get { return isSingleParentChild; }
            set
            {
                isSingleParentChild = value;
                OnPropertyChanged(this, new PropertyChangedEventArgs(nameof(IsSingleParentChild)));
            }
        }

        string isDeformityParentsChild = "";
        /// <summary>
        /// 是否残疾人子女。
        /// ★注意：是文本型。只允许“是”和“否”。
        /// </summary>
        public string IsDeformityParentsChild
        {
            get { return isDeformityParentsChild; }
            set
            {
                isDeformityParentsChild = value;
                OnPropertyChanged(this, new PropertyChangedEventArgs(nameof(IsDeformityParentsChild)));
            }
        }

        string studentDeformityStatus = "";
        /// <summary>
        /// 学生本人残疾情况。必须是下列五种之一：
        /// 无残疾
        /// 视力残疾
        /// 听力残疾
        /// 智力残疾
        /// 其他残疾
        /// </summary>
        public string StudentDeformityStatus
        {
            get { return studentDeformityStatus; }
            set
            {
                studentDeformityStatus = value;
                OnPropertyChanged(this, new PropertyChangedEventArgs(nameof(StudentDeformityStatus)));
            }
        }

        string isParentsCanNotWork = "";
        /// <summary>
        /// 是否父母丧失劳动能力。
        /// ★注意：是文本型。只允许“是”和“否”。
        /// </summary>
        public string IsParentsCanNotWork
        {
            get { return isParentsCanNotWork; }
            set
            {
                isParentsCanNotWork = value;
                OnPropertyChanged(this, new PropertyChangedEventArgs(nameof(IsParentsCanNotWork)));
            }
        }

        string isSeriousIllnessInTheFamily = "";
        /// <summary>
        /// 是否家中有大病患者。
        /// ★注意：是文本型。只允许“是”和“否”。
        /// </summary>
        public string IsSeriousIllnessInTheFamily
        {
            get { return isSeriousIllnessInTheFamily; }
            set
            {
                isSeriousIllnessInTheFamily = value;
                OnPropertyChanged(this, new PropertyChangedEventArgs(nameof(IsSeriousIllnessInTheFamily)));
            }
        }

        string isArmyOrSpecialCaredChild = "";
        /// <summary>
        /// 是否军烈属或优抚子女。
        /// ★注意：是文本型。只允许“是”和“否”。
        /// </summary>
        public string IsArmyOrSpecialCaredChild
        {
            get { return isArmyOrSpecialCaredChild; }
            set
            {
                isArmyOrSpecialCaredChild = value;
                OnPropertyChanged(this, new PropertyChangedEventArgs(nameof(IsArmyOrSpecialCaredChild)));
            }
        }

        string annualHouseholdIncome = "";
        /// <summary>
        /// 家庭年人均收入。
        /// ★注意：必须是整数，但以文本形式存储。数值不能大于6位数（即不能大于999999）。
        /// </summary>
        public string AnnualHouseholdIncome
        {
            get { return annualHouseholdIncome; }
            set
            {
                annualHouseholdIncome = value;
                OnPropertyChanged(this, new PropertyChangedEventArgs(nameof(AnnualHouseholdIncome)));
            }
        }

        string sourceOfFamilyIncome = "";
        /// <summary>
        /// 家庭收入主要来源类型。
        /// 1-工资、奖金、津贴、补贴和其他劳动收入
        /// 2-离退休金、基本养老金、基本生活费、失业保险金
        /// 3-继承、接受赠予、出租或出售家庭财产获得的收入
        /// 4-存款及利息，有价证券及红利、股票、博彩收入
        /// 5-经商、办厂以及从事种植业、 养殖业、加工业扣除必要成本后的收入
        /// 6-赡养费、抚(扶)养费
        /// 7-自谋职业收入
        /// 8-其他应当计入家庭的收入
        /// </summary>
        public string SourceOfFamilyIncome
        {
            get { return sourceOfFamilyIncome; }
            set
            {
                sourceOfFamilyIncome = value;
                OnPropertyChanged(this, new PropertyChangedEventArgs(nameof(SourceOfFamilyIncome)));
            }
        }

        string isSufferFromNaturalDisasters = "";
        /// <summary>
        /// 是否遭受自然灾害。
        /// ★注意：是文本型。只允许“是”和“否”。
        /// </summary>
        public string IsSufferFromNaturalDisasters
        {
            get { return isSufferFromNaturalDisasters; }
            set
            {
                isSufferFromNaturalDisasters = value;
                OnPropertyChanged(this, new PropertyChangedEventArgs(nameof(IsSufferFromNaturalDisasters)));
            }
        }

        string naturalDisastersDiscription = "";
        /// <summary>
        /// 自然灾害具体情况描述（40字以内）。
        /// </summary>
        public string NaturalDisastersDiscription
        {
            get { return naturalDisastersDiscription; }
            set
            {
                naturalDisastersDiscription = value;
                OnPropertyChanged(this, new PropertyChangedEventArgs(nameof(NaturalDisastersDiscription)));
            }
        }

        string isUnexpectedAccidentHappened = "";
        /// <summary>
        /// 是否遭受突发意外事件。
        /// </summary>
        public string IsUnexpectedAccidentHappened
        {
            get { return isUnexpectedAccidentHappened; }
            set
            {
                isUnexpectedAccidentHappened = value;
                OnPropertyChanged(this, new PropertyChangedEventArgs(nameof(IsUnexpectedAccidentHappened)));
            }
        }

        string unexpectedAccidentDiscription = "";
        /// <summary>
        /// 突发意外事件具体情况描述。
        /// </summary>
        public string UnexpectedAccidentDiscription
        {
            get { return unexpectedAccidentDiscription; }
            set
            {
                unexpectedAccidentDiscription = value;
                OnPropertyChanged(this, new PropertyChangedEventArgs(nameof(UnexpectedAccidentDiscription)));
            }
        }

        string amountOfDebt = "0";
        /// <summary>
        /// 家庭所欠债务金额。
        /// </summary>
        public string AmountOfDebt
        {
            get { return amountOfDebt; }
            set
            {
                if (string.IsNullOrWhiteSpace(value))
                {
                    amountOfDebt = "0";
                }
                else amountOfDebt = value;
                OnPropertyChanged(this, new PropertyChangedEventArgs(nameof(AmountOfDebt)));
            }
        }

        string debtReson = "";
        /// <summary>
        /// 家庭负债原因。
        /// </summary>
        public string DebtReson
        {
            get { return debtReson; }
            set
            {
                debtReson = value;
                OnPropertyChanged(this, new PropertyChangedEventArgs(nameof(DebtReson)));
            }
        }

        string familyMembersCount = "";
        /// <summary>
        /// 家庭人口数。若填写0，则实际存储的值会是空字符串。
        /// </summary>
        public string FamilyMembersCount
        {
            get
            {
                return familyMembersCount;
            }
            set
            {
                if (string.IsNullOrWhiteSpace(value))
                {
                    familyMembersCount = "1";//至少1个家庭成员。
                }
                else
                {
                    familyMembersCount = value;
                }
                OnPropertyChanged(this, new PropertyChangedEventArgs(nameof(FamilyMembersCount)));
            }
        }

        string supportPersonsCount = "";
        /// <summary>
        /// 赡养人口数。若填写0，则实际存储的值会是空字符串。
        /// </summary>
        public string SupportPersonsCount
        {
            get
            {
                return supportPersonsCount;
            }
            set
            {
                if (string.IsNullOrWhiteSpace(value))
                {
                    supportPersonsCount = "0";
                }
                else supportPersonsCount = value;
                OnPropertyChanged(this, new PropertyChangedEventArgs(nameof(SupportPersonsCount)));
            }
        }

        string isRegistedPoorFamily = "";
        /// <summary>
        /// 是否建档立卡贫困户。
        /// </summary>
        public string IsRegistedPoorFamily
        {
            get { return isRegistedPoorFamily; }
            set
            {
                isRegistedPoorFamily = value;
                OnPropertyChanged(this, new PropertyChangedEventArgs(nameof(IsRegistedPoorFamily)));
            }
        }

        string isRegistedBasicLivingAllowances = "";
        /// <summary>
        /// 是否建档立卡低保贫困户。
        /// </summary>
        public string IsRegistedBasicLivingAllowances
        {
            get { return isRegistedBasicLivingAllowances; }
            set
            {
                isRegistedBasicLivingAllowances = value;
                OnPropertyChanged(this, new PropertyChangedEventArgs(nameof(IsRegistedBasicLivingAllowances)));
            }
        }

        string otherInfosFromCivilDepartment = "";
        /// <summary>
        /// 扶贫或民政部门其它认证信息。不超过40个字。
        /// </summary>
        public string OtherInfosFromCivilDepartment
        {
            get { return otherInfosFromCivilDepartment; }
            set
            {
                otherInfosFromCivilDepartment = value;
                OnPropertyChanged(this, new PropertyChangedEventArgs(nameof(OtherInfosFromCivilDepartment)));
            }
        }

        string laborCountOfFamily = "";
        /// <summary>
        /// 劳动力人口数。
        /// ★注意：必须是整数，但以文本形式存储。如果为0，相当于空字符串。
        /// </summary>
        public string LaborCountOfFamily
        {
            get { return laborCountOfFamily; }
            set
            {
                if (string.IsNullOrWhiteSpace(value))
                {
                    laborCountOfFamily = "0";
                }
                else laborCountOfFamily = value;
                OnPropertyChanged(this, new PropertyChangedEventArgs(nameof(LaborCountOfFamily)));
            }
        }

        string unemployedCountOfFamily = "";
        /// <summary>
        /// 家庭失业人口数。指适龄人口中未就业的。
        /// </summary>
        public string UnemployedCountOfFamily
        {
            get { return unemployedCountOfFamily; }
            set
            {
                if (string.IsNullOrWhiteSpace(value))
                {
                    unemployedCountOfFamily = "0";
                }
                else unemployedCountOfFamily = value;
                OnPropertyChanged(this, new PropertyChangedEventArgs(nameof(UnemployedCountOfFamily)));
            }
        }

        string otherInfos = "";
        /// <summary>
        /// 其它特殊情况补充说明。400字以内。
        /// </summary>
        public string OtherInfos
        {
            get { return otherInfos; }
            set
            {
                otherInfos = value;
                OnPropertyChanged(this, new PropertyChangedEventArgs(nameof(OtherInfos)));
            }
        }
    }
}
